
function XHRpost(url, data, onSuccess) {
    $.ajax
            ({
                type: "POST",
                url: url,
                dataType: 'json',
                data: data,
                success: onSuccess
            })
}

function XHRget(url, data, onSuccess){
     $.ajax
            ({
                type: "GET",
                url: url, 
                data: data,
                success: onSuccess
            })
}



